<!doctype html>
<html class="no-js">
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="description" content="">
    <meta name="keywords" content="">
    <meta name="renderer" content="webkit">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>{$sysInfo.title}</title>
    {load_js('jquery')}
    {load_ui($sysPublic)}
    <link rel="stylesheet" href="{$sysPublic}/system/css/style.css">
    <script type="text/javascript" src="{$sysPublic}/system/js/lib.js"></script>
</head>
<body>
<aside class="dux-moblie-aside">
    <ul>
        <!--loop{$sysNav as $top}-->
        <li>
            <h3>{$top.name}</h3>
            <ul>
                <!--loop{$top.menu as $parent}-->
                <li><h4><i class="fa fa-{$parent.icon}"></i> {$parent.name}</h4>
                    <ul>
                        <!--loop{$parent.menu as $sub}-->
                        <li  <!--if{$sub.cur}-->class="active"<!--{/if}--> ><a href="{$sub.url}"><i
                            class="fa fa-{$sub.icon}"></i> {$sub.name}</a></li>
                        <!--{/loop}-->
                    </ul>
                </li>
                <!--{/loop}-->
            </ul>
        </li>
        <!--{/loop}-->
    </ul>
</aside>
<header class="dux-moblie-header">
    <h3>{$sysInfo.name}</h3>
    <a href="javascript:;" class="menu-left" data-dux="base-menu"><i class="fa fa-bars"></i></a>
    <a href="" class="menu-right"><i class="fa fa-cog"></i></a>
</header>
<div class="dux-html">
    <header class="dux-system-nav">
        <nav class="navbar">
            <div class="brand">
                {$sysInfo.name}
                <small>平台管理系统</small>
            </div>

            <div class="collapse">
            <ul class="menu">
                <!--loop{$sysNav as $vo}-->
                <li class="{$vo.cur ? 'active' : ''}">
                    <a href="{$vo.url}">{$vo.name}</a>
                </li>
                <!--{/loop}-->
            </ul>

            <ul class="tools">
                <li>
                    <a href="{url('default/index/Index/index')}" target="_blank"><i class="fa fa-home"></i></a>
                </li>
                <li>
                    <a href="{url('system/Index/userData')}"><i class="fa fa-user"></i></a>
                </li>
                <li>
                    <a href="{url('system/Login/logout')}"><i class="fa fa-power-off"></i></a>
                </li>
            </ul>
            </div>
        </nav>

        <nav class="dux-system-info">
            <!--if{empty($sysTabs)}-->
            <div class="info">{$infoModule.info.name}
                <small>{$infoModule.info.description}</small>
            </div>
            <!--{else}-->
            <div class="list">
                <ul>
                    <!--loop{$sysTabs as $vo}-->
                    <li class="{$vo.cur ? 'active' : ''}">
                        <a href="{$vo.url}">{$vo.name}</a>
                    </li>
                    <!--{/loop}-->
                </ul>
            </div>
            <!--{/if}-->
        </nav>
    </header>


    <aside class="dux-aside">
        <div class="aside-main">
            <ul>
                <!--loop{$sysAside as $vo}-->
                <li class=" {$vo.cur ? 'active' : ''}">
                    <a href="javascript:;">
                        <i class="fa fa-{$vo.icon}"></i>
                        <p>{$vo.name}</p>
                    </a>
                </li>
                <!--{/loop}-->
            </ul>
        </div>
        <div class="aside-sub">
            <!--loop{$sysAside as $vo}-->
            <div class="sub-item {$vo.cur ? 'active' : ''}">
                <div class="name">{$vo.name}</div>
                <ul>
                    <!--loop{$vo.menu as $sub}-->
                    <li class="{$sub.cur ? 'active' : ''}">
                        <a href="{$sub.url}">
                            <p>{$sub.name}</p>
                        </a>
                    </li>
                    <!--{/loop}-->
                </ul>
            </div>
            <!--{/loop}-->
        </div>
    </aside>


    <div class="dux-mobile-bg"></div>

    <main class="dux-main">
        {$layout}
        <div class="uk-text-center uk-padding">©CopyRight 2013~{date('Y')} {$sysInfo.name}, All Rights
            Reserved. <?php echo \dux\Dux::runTime(); ?>s
        </div>
    </main>
</div>
</body>

<script>
    Do('base', function () {
        base.frame();
        $('.aside-main').on('click', 'a', function () {
            $('.aside-main').find('li').removeClass('active');
            $(this).parent('li').addClass('active');
            var num = $(this).parent('li').index();
            $('.aside-sub').find('.sub-item').removeClass('active');
            $('.aside-sub').find('.sub-item').eq(num).addClass('active');

        });
    });
</script>
</html>